const obj = {
  name: 'zhangsna',
};

const prototype = {
  name: 'lisi',
};

const p = new Proxy(obj, {
  /**
   *
   * @param {*} target 源对象
   * @returns 必须返回一个object或者null
   */
  getPrototypeOf: (target) => {
    console.log(target);
    return prototype;
  },
});
console.log('p.__proto__ ==>', p.__proto__); // 可以被拦截
console.log('Object.getPrototypeOf(p) ==>', Object.getPrototypeOf(p)); // 可以被拦截
